/**
Copyright (c) 2008 Arnaud Fabre <arnaud333@gmail.com>
Copyright (c) 2008 Pierre "delroth" Bourdon <root@delroth.is-a-geek.org>

This file is part of Vos Tutos Offline.

Vos Tutos Offline is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Vos Tutos Offline is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with Vos Tutos Offline.  If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef _VTO_DOC_BIGTUTO_H
#define _VTO_DOC_BIGTUTO_H

#include "doc_minitutorial.h"

#include <QString>
#include <QList>
#include <QDomDocument>
#include <QDomElement>

/** A big tutorial part */

class BigTutorialPart : public IntroducedDocument
{
	
public:
    BigTutorialPart(const QString& title = QString());
    BigTutorialPart(const QDomElement& de);
    ~BigTutorialPart();

    QDomElement toDomElement(QDomDocument& doc) const;
    void fromDomElement(const QDomElement& de);

    QList<MiniTutorial*>& allChapters();

protected:
    QList<MiniTutorial*> chapters;
};

/** A big tutorial */

class BigTutorial : public IntroducedDocument
{
	
public:
    BigTutorial(const QString& title = QString());
    BigTutorial(const QDomElement& de);
    ~BigTutorial();

    QDomElement toDomElement(QDomDocument& doc) const;
    void toFile(const QString& fname);
    
    void fromDomElement(const QDomElement& de);
    void fromFile(const QString& fname);
   
    QList<BigTutorialPart*>& allParts();

protected:
    QList<BigTutorialPart*> parts;
};


#endif
